package com.hiabr.iep.common.web.config;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Configuration;

import java.util.List;

/**
 * @author jiehuang
 */
@Data
@Configuration
@EnableConfigurationProperties(TenantProperties.class)
@ConfigurationProperties("mybatis-plus.multi-tenant")
public class TenantProperties {
    /**
     * 忽略多租户的表
     */
    private List<String> ignoreTable;

    /**
     * 租户 ID 列名
     */
    private String idColumn = "tenant_id";

    /**
     * 是否开启多租户
     */
    private boolean enable = false;

    /**
     * 是否开启超级管理员所有租户数据权限
     */
    private boolean adminEnable = false;
}
